package com.xiaoshuai;

import org.springframework.context.support.ClassPathXmlApplicationContext;

public class ConsumerClient {
	public static void main(String[] args) {
		try {
			ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext("consumer.xml");
			HelloService helloService = (HelloService) context.getBean("helloService");
			String result = helloService.speakHello("charles");
			System.out.println(result);
			System.in.read();
		} catch (Exception e) {
			e.printStackTrace();
		}
	}
}
